-- GENERATED SPELL FOR [Luanga the Imprisoner] --


function spell0_18533(pUnit, Event) --@Arakkoa Blast,n/a--
pUnit:FullCastSpellOnTarget(32907,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18533', 600, 1)
end

function spell1_18533(pUnit, Event) --@Chain Lightning,n/a--
pUnit:FullCastSpellOnTarget(12058,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18533', 3000, 1)
end

function spell2_18533(pUnit, Event) --@Lightning Cloud,n/a--
pUnit:FullCastSpellOnTarget(6535,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18533', 18000, 1)
end

function spell3_18533(pUnit, Event) --@Power of Kran\'aish,n/a--
pUnit:FullCastSpellOnTarget(32924,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18533', 0, 1)
end

function spell4_18533(pUnit, Event) --@Shock,n/a--
pUnit:FullCastSpellOnTarget(11824,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18533', 0, 1)
end

function Sorts_18533(pUnit, Event)
local choix_sorts_18533 = math.random(0, 4)
if choix_sorts_18533 == 0 then
pUnit:RegisterEvent('spell0_18533', 1, 1)
end
if choix_sorts_18533 == 1 then
pUnit:RegisterEvent('spell1_18533', 1, 1)
end
if choix_sorts_18533 == 2 then
pUnit:RegisterEvent('spell2_18533', 1, 1)
end
if choix_sorts_18533 == 3 then
pUnit:RegisterEvent('spell3_18533', 1, 1)
end
if choix_sorts_18533 == 4 then
pUnit:RegisterEvent('spell4_18533', 1, 1)
end
end

function mob18533_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_18533', math.random(1500, 3000), 1)
end

function mob18533_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob18533_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob18533_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(18533, 1, 'mob18533_Action')
RegisterUnitEvent(18533, 2, 'mob18533_Leave')
RegisterUnitEvent(18533, 3, 'mob18533_Kill')
RegisterUnitEvent(18533, 4, 'mob18533_Die')
